package com.kotlin.demo.constant

import androidx.compose.runtime.mutableStateOf
import com.kotlin.demo.bean.TranslateConfigBean
import com.kotlin.demo.enums.DialogType
import kotlinx.coroutines.MainScope

object Constants {
    val TRANSLATE_LIST_TAG =// 多语言翻译列表 key  代表翻译的 简体| value 代表安卓目录 value 的命名
        arrayListOf(
            TranslateConfigBean(
                name = "中文",
                shortName = "zh",
                valuesName = "zh-rCN",
                apiName = "zht",
                errorName = "desc",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "英语",
                shortName = "en",
                valuesName = "en",
                apiName = "en",
                errorName = "descEn",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "韩语",
                shortName = "ko",
                valuesName = "ko",
                apiName = "ko",
                errorName = "descKo",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "日语",
                shortName = "ja",
                valuesName = "ja",
                apiName = "ja",
                errorName = "descJa",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "土耳其语",
                shortName = "tr",
                valuesName = "tr",
                apiName = "tr",
                errorName = "descTr",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "捷克语",
                shortName = "cs",
                valuesName = "cs",
                apiName = "cs",
                errorName = "descCze",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "阿拉伯语",
                shortName = "ar",
                valuesName = "ar",
                apiName = "ar",
                errorName = "descAr",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "德语",
                shortName = "de",
                valuesName = "de",
                apiName = "de",
                errorName = "descDe",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "西班牙语",
                shortName = "es",
                valuesName = "es",
                apiName = "es",
                errorName = "descDe",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "罗马尼亚语",
                shortName = "ro",
                valuesName = "ro",
                apiName = "ro",
                errorName = "descRo",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "俄语",
                shortName = "ru",
                valuesName = "ru",
                apiName = "ru",
                errorName = "descRu",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "乌克兰语",
                shortName = "uk",
                valuesName = "uk",
                apiName = "uk",
                errorName = "descUk",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "中文繁体",
                shortName = "zhTW",
                valuesName = "zh-rTW",
                apiName = "cht",
                errorName = "descCnTw",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "波兰语",
                shortName = "pl",
                valuesName = "pl",
                apiName = "pl",
                errorName = "descCnPl",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "法语",
                shortName = "fr",
                valuesName = "fr",
                apiName = "fr",
                errorName = "descFr",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "意大利语",
                shortName = "it",
                valuesName = "it",
                apiName = "it",
                errorName = "descIt",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "蒙古语",
                shortName = "mn",
                valuesName = "mn",
                apiName = "mn",
                errorName = "descMo",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "荷兰语",
                shortName = "nl",
                valuesName = "nl",
                apiName = "nl",
                errorName = "descNl",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "泰语",
                shortName = "th",
                valuesName = "th",
                apiName = "th",
                errorName = "descTh",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "匈牙利语",
                shortName = "hu",
                valuesName = "hu",
                apiName = "hu",
                errorName = "descHu",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "保加利亚语",
                shortName = "bg",
                valuesName = "bg",
                apiName = "bg",
                errorName = "descBg",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "斯洛伐克",
                shortName = "sk",
                valuesName = "sk",
                apiName = "sk",
                errorName = "descSk",
                isNeedTranslate = true
            ),
            TranslateConfigBean(
                name = "哈萨克语",
                shortName = "kz",
                valuesName = "kz",
                apiName = "ka",
                errorName = "descKz",
                isNeedTranslate = true
            )
        )

    // 使用 remember 来记忆 isLoading 的状态
    var isShowDialog = mutableStateOf(false) //dialog 显示
    var dialogType = mutableStateOf(DialogType.LOADING) //当前 提示 dialog 显示类型
    var tipsContent = mutableStateOf("正在加载中...请稍后！")   //当前提示 dialog 显示内容
    var resPath = mutableStateOf("") //翻译写入路径
    var translateInput = mutableStateOf("") // 输入的翻译内容
    var translateResultText = mutableStateOf("") // 翻译结果
    var translateKey = mutableStateOf("") // 翻译key
    var isExpandResPath = mutableStateOf(false) //路径列表展开|关闭
    var mainScope = MainScope()//全局协程

}